package cn.edu.zut.soft.graduate.controller;

import cn.edu.zut.soft.basic.core.model.bo.CommonResult;
import cn.edu.zut.soft.graduate.core.query.MassageQuery;
import cn.edu.zut.soft.graduate.massageCenter.bo.MessageBO;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.annotation.Resource;
import javax.servlet.http.HttpSession;

/**
 * Created by chuchuang on 16/11/13.
 */
@Controller
@RequestMapping("massage")
public class MassageController extends BaseController {

    @Resource
    private MessageBO messageBO;

    @ResponseBody
    @RequestMapping("query")
    public CommonResult myInBox(HttpSession session,MassageQuery massageQuery){
        return CommonResult.successReturn(messageBO.get(massageQuery.getId()));
    }
}
